public class Assignatura {
	private String nomAssignatura;
	private int numAlumnes;
	private int[] notesAlumnes;
	private String[] Llibres = {"llibre1", "llibre2", "llibre3", "llibre4", "llibre5"};
	private String professor;
	
	public String getNom() {
		return nomAssignatura;
	}
	public void setNom(String nom) {
		this.nomAssignatura = nom;
	}
	
	public int getNumAlumnes() {
		return numAlumnes;
	}
	public void setNumAlumnes(int numAlumnes) {
		this.numAlumnes = numAlumnes;
	}
	
	public int[] getNotesAlumnes() {
		return notesAlumnes;
	}
	public void setNotesAlumnes(int[] notesAlumnes) {
		this.notesAlumnes = notesAlumnes;
	}
	
	public String[] getLlibres() {
		return Llibres;
	}
	public void setLlibres(String[] Llibres) {
		this.Llibres = Llibres;
	}
	
	public String getProfessor() {
		return professor;
	}
	public void setProfessor(String professor) {
		this.professor = professor;
	}
	
	public int calculaNotaMitja(int[] a){
		int mitjana=0;
		int size = a.length;
		for (int i=0; i < size; i++){
			mitjana += a[i];
		}
		return mitjana/size;
	}
	
	public int calculaNotaMaxima(int[] a){
		int max=a[0];
		int size = a.length;
		for (int i=1; i < size; i++){
			if (a[i]>max)max=a[i];
		}
		return max;
	}
}
